<!DOCTYPE html>
<html>
<head>
  <meta charset="UTF-8">
  <title>Document</title>
  <style>
    
  </style>
</head>
<body>
  <input type="text" class="search">
  <ul class="list">
  </ul>
</body>
<script>

  $(".search").oninput = function(){
    const script = document.createElement("script")
    script.src = "https://suggest.taobao.com/sug?k=1&area=c2c&q="+ this.value +"&code=utf-8&callback=abc";
    document.body.appendChild(script);
    
    window.abc = function(res){
      let str = "";
      res.result.forEach(val=>{
        str += `<li>${val[0]}</li>`
      })
      $(".list").innerHTML = str;
      script.remove();
    }
  }
  
  

  function $(s){
    return document.querySelector(s)
  }

</script>
</html>